package com.weipai.education.mapper;

import com.weipai.education.model.InventoryDetail;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface InventoryDetailMapper {
    int deleteByPrimaryKey(Integer id);

    List<Map<String,Integer>> selectDetailPeoduct(@Param("productId") Integer productId,@Param("userId")Integer userId,@Param("totalNumber")Integer totalNumber);

    int insert(InventoryDetail record);

    int insertSelective(InventoryDetail record);

    InventoryDetail selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(InventoryDetail record);

    int updateByPrimaryKey(InventoryDetail record);

    InventoryDetail getInventoryDetail(@Param("userId") String userId, @Param("productId") String productId, 
                                       @Param("goodsBarCode") String goodsBarCode);

    List<Map<String,Object>> getUserGoodsBar(@Param("productId") Integer productId,
                                             @Param("userId") String userId);
}